import request from '@/utils/request';
import { getCurrentInstance } from 'vue';
const errortips =
  getCurrentInstance()?.appContext.config.globalProperties.$errortips;

/**
 * 分页查询用户
 */
//支付
export async function pay(params) {
  const res = await request.post('/order/pay/pay', {
    ...params
  });
  if (res.data.code === 1) {
    return res.data;
  }
  return Promise.reject(res.data.msg || errortips);
}
